const {
	$USetCache,
	$UGetCache,
	$URemoveCacheAll,
} = require('@utils/storage')

module.exports = {

	LOG_IN(state, userInfo) {
		state.userInfo = userInfo
		$USetCache('userInfo', userInfo)
	},

	LOG_OUT(state) {
		state.userInfo = null
		$URemoveCacheAll()
	},

	TASK_ITEM_LIST(state, datas) {
		state.datas = datas
	},
}